package com.example.xm.adapter.ownAdapter;

import android.content.Context;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.example.xm.R;
import com.example.xm.base.BaseAdapter;

import java.util.ArrayList;
import java.util.List;

import butterknife.BindView;

public class OwnRlvAdapter extends BaseAdapter {
    @BindView(R.id.iv_img_own_item)
    ImageView ivImgOwnItem;
    @BindView(R.id.tv_title_own_item)
    TextView tvTitleOwnItem;

    public OwnRlvAdapter(Context context, List data) {
        super(context, data);
    }

    @Override
    protected int getLayout() {
        return R.layout.fragment_own_item;
    }

    @Override
    protected void bindData(BaseViewHolder viewHolder, Object o) {
        ImageView img = (ImageView) viewHolder.getViewById(R.id.iv_img_own_item);
        TextView title = (TextView) viewHolder.getViewById(R.id.tv_title_own_item);
        String str = (String) o;
        title.setText(str);
    }
}
